<div class="modal-dialog" role="document" style="width:700px;">
    <div class="modal-content">
        <div class="modal-header">
            <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
            <h4 class="modal-title" id="exampleModalLabel">订单明细 - <small>{$row.order_no}</small></h4>
        </div>
        <form role="form" style="padding:4%;height:500px;overflow-y:auto;">
            <div class="form-group">
                <label class="control-label">行程:</label>
                <div>
                    <span>{$row.trip.origin} （{$row.trip.depart_date|date="Y年m月d日 H:i",###}） - {$row.trip.destination} （{$row.trip.reach_date|date="Y年m月d日 H:i",###}）</span>
                </div>
            </div>
            <div class="row">
                <div class="form-group col-sm-6">
                    <label class="control-label">旅客:</label>
                    <div>
                        <span>{$row.seller.real_name}</span>
                        <img src="{$row.seller.avatar}" class="img-circle" style="width: 60px; margin-left: 10px;">
                    </div>
                </div>
                <div class="form-group col-sm-6">
                    <label class="control-label">客户:</label>
                    <div>
                        <span>{$row.buyer.real_name}</span>
                        <img src="{$row.buyer.avatar}" class="img-circle" style="width: 60px; margin-left: 10px;">
                    </div>
                </div>
            </div>
            <div class="row">
                <div class="form-group col-sm-6">
                    <label class="control-label">订单编号:</label>
                    <div>
                        {$row.order_no}
                    </div>
                </div>
                <div class="form-group col-sm-6">
                    <label class="control-label">订单类型/状态:</label>
                    <div>
                        <switch name="row.type">
                            <case value="1"><span class="label label-primary">货运订单</span></case>
                            <case value="2"><span class="label label-info">查询联系方式订单</span></case>
                            <default /><span class="label label-default">其它</span>
                        </switch> /
                        <if condition="$row['type'] eq 1">
                            <switch name="row.state">
                                <case value="0"><span class="label label-default">已抢单</span></case>
                                <case value="1"><span class="label label-info">已接单</span></case>
                                <case value="2"><span class="label label-primary">进行中</span></case>
                                <case value="3"><span class="label label-info">已确认</span></case>
                                <case value="4"><span class="label label-info">已尽力</span></case>
                                <case value="5"><span class="label label-warning">已取消</span></case>
                                <case value="6"><span class="label label-warning">已取消 - 未完成</span></case>
                                <case value="7"><span class="label label-warning">已取消 - 拒绝接单</span></case>
                                <case value="8"><span class="label label-success">已完成</span></case>
                                <case value="9"><span class="label label-danger">已删除</span></case>
                                <default /><span class="label label-default">其它</span>
                            </switch>
                        <else/>
                            <span class="label label-success">已完成</span>
                        </if>
                    </div>
                </div>
            </div>
            <div class="row">
                <div class="form-group col-sm-6">
                    <label class="control-label">订单总金额:</label>
                    <div>
                        <span>{$row.totalAmount|number_format=2} 元</span>
                    </div>
                </div>
                <div class="form-group col-sm-6">
                    <label class="control-label">下单时间:</label>
                    <div>
                        <span>{$row.add_time|date="Y-m-d H:i:s",###}</span>
                    </div>
                </div>
            </div>
            <div class="row">
                <div class="form-group col-sm-6">
                    <label class="control-label">赏金:</label>
                    <div>
                        <span>{$row.reward|number_format=2} 元</span>
                    </div>
                </div>
                <div class="form-group col-sm-6">
                    <label class="control-label">保证金:</label>
                    <div>
                        <span>{$row.deposit|number_format=2} 元</span>
                    </div>
                </div>
            </div>
            <div class="form-group">
                <label class="control-label">手续费:</label>
                <div>
                    <span>{$row.brokerage|number_format=2} 元</span>
                </div>
            </div>
            <div class="form-group">
                <label class="control-label">联系方式:</label>
                <div>
                    <if condition="$row['contact']['tel']"> <p style="margin-bottom: 0px;">手机：{$row.contact.tel}</p></if>
                    <if condition="$row['contact']['wx']"> <p style="margin-bottom: 0px;">微信：{$row.contact.wx}</p></if>
                </div>
            </div>
            <if condition="$row['type'] eq 1">
                <div class="form-group">
                    <label class="control-label">需求描述:</label>
                    <textarea class="form-control" rows="5">{$row.remark}</textarea>
                </div>
                <div class="form-group">
                    <label class="control-label">图片:</label>
                    <div>
                        <foreach name="row.attachment" item="attache">
                            <img src="__ROOT__{$attache.attachment}" style="width:60px;height:60px;margin:10px;">
                        </foreach>
                    </div>
                </div>
            </if>
        </form>
        <div class="modal-footer">
            <button type="button" data-dismiss="modal" class="btn btn-default">取消</button>
        </div>
    </div>
</div>